package com.itheima.controller;

import com.alibaba.dubbo.config.annotation.Reference;
import com.itheima.entity.Result;
import com.itheima.service.ValidateCodeService;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("validateCode")
public class ValidateCodeController {
    @Reference(version = "1.0")
    ValidateCodeService validateCodeService;

    //"/validateCode/send4Login.do?telephone=" + telephone
    @PostMapping("send4Login")
    public Result send4Login(String telephone){
        return validateCodeService.send4Login(telephone);
    }
}
